import Instance from '@/utils/http.ts';

export function useMenuInfoAPI(){
    return Instance({
        url:'/sys-menu/getBaseMenu',
        method:'GET'
    })
}

export function useFullMenuInfoPI(){
    return Instance({
        url:'/sys-menu/getAllMenus',
        method:'GET',
    })
}

export function useMenuByPidLevelAPI(pid:number,level:number){
    return Instance({
        url:'/sys-menu/getChoseMenuList',
        method:'GET',
        params: {pid: pid, level: level}
    })
}
export function useBaseMenusAPI(){
    return Instance({
        url:'/sys-menu/getBaseMenu',
        method:'GET',
    })
}

export function useChoseMenusAPI(pid:number,level:number){
    return Instance({
        url:'/sys-menu/getChoseMenuList',
        method:'GET',
        params:{
            pid:pid,
            level:level
        }

    })
}